<template>
  <div class="detail-item">
      <div>{{title}}</div>
      <div v-if="percentage">
        <!-- 默认是有值的 -->
        <div class="percent-num" :class="[trend !== 'UP' ? 'increase-num' : 'reduce-num']">
          <i class="percent-icon"></i>
          <span>{{percentage}}</span>
        </div>
      </div>
      <div v-else>
        --
      </div>
  </div>
</template>
<script>
export default {
  props: {
    percentage: {
      type: String,
      default: '',
    },
    trend: {
      type: String,
      default: '',
    },
    title: {
      type: String,
      default: '',
    }
  }
}
</script>